﻿//-----------------------------------------------------------------------
// <copyright file="ICommandHandlingManager.cs" author="Artak Mkrtchyan">
//     Creative Commons - GNU General Public License (http://creativecommons.org/licenses/GPL/2.0/
// </copyright>
// <author>Artak Mkrtchyan</author>
// <email>mkArtak@gmail.com</email>
// <date>21/10/2012</date>
//-----------------------------------------------------------------------
using System;

namespace ConsoleHoster.Common.Model
{
	/// <summary>
	/// Represents a contract for interacting with the command handling engine.
	/// </summary>
	public interface ICommandHandlingManager
	{
		/// <summary>
		/// Registeres the specified handler to be run for the specified command, after actual execution of it
		/// </summary>
		/// <param name="argCommand">The command executed</param>
		/// <param name="argHandler">The handler delegate</param>
		void RegisterPostProcessCommandHandler(string argCommand, Action<string> argHandler);
		
		/// <summary>
		/// Registeres the specified handler to be run for the specified command, before actual execution of it
		/// </summary>
		/// <param name="argCommand">The command executed</param>
		/// <param name="argHandler">The handler delegate</param>
		void RegisterPreProcessCommandHandler(string argCommand, Action<string> argHandler);
	}
}
